package com.wise.model.content.enums;

public enum ArticleEnum {

    //    媒体聚焦1, 通知公告2, 新闻动态(大类)3, 中心党建(类别)4, 研究所党建5, 创新综合体党建6, 招聘(大类)7
    MTJJ(1, false),

    TZGG(2, false),

    XWDT(3, true),

    ZXDJ(4, true),

    YJSDJ(5, false),

    CXZHT(6, false),

    ZP(7, true)

    ,
    ;

    private final int type;

    private final boolean hasColumn;

    ArticleEnum(int type, boolean hasColumn) {
        this.type = type;
        this.hasColumn = hasColumn;
    }

    public static ArticleEnum getThisFromType(Integer type) {
        for (ArticleEnum value : ArticleEnum.values()) {
            if (value.getType() == type) {
                return value;
            }
        }
        return null;
    }

    public int getType() {
        return type;
    }

    public boolean isHasColumn() {
        return hasColumn;
    }
}
